#ifndef HOME_H
#define HOME_H

#include <QWidget>
#include "global_client.h"


namespace Ui {
class home;
}

class home : public QWidget
{
    Q_OBJECT

public:
    explicit home(QWidget *parent = nullptr);
    ~home();

private slots:
    void on_toolButton_addPeople_clicked();

    void on_toolButton_quit_clicked();

    void on_toolButton_startChat_clicked();

    void on_toolButton_deletePeople_clicked();

    void on_toolButton_sendMessage_clicked();

private:
    Ui::home *ui;
    QList<User> myFriendList;
    int listnum = 0;

    void refreshFriendList();
    void closeEvent(QCloseEvent *event);
};

#endif // HOME_H
